import 'package:flutter/material.dart';
import '../controls/basic/e_tab.dart';
import 'channel_setting.dart';

class AcquisitionAnalysisPage extends StatefulWidget {
  const AcquisitionAnalysisPage({super.key});

  @override
  State<AcquisitionAnalysisPage> createState() => _AcquisitionAnalysisPageState();
}

class _AcquisitionAnalysisPageState extends State<AcquisitionAnalysisPage> {
  // 当前激活的标签名
  String _activeName = 'settings';

  @override
  Widget build(BuildContext context) {
    return ETabs(
      activeName: _activeName,
      position: ETabPosition.top,
      type: ETabType.card,
      size: ETabSize.large,
      bottomBorder: true,
      onTabClick: (name, label) {
        setState(() {
          _activeName = name;
        });
      },
      children: [
        // 设置标签页
        ETabPane(
          label: '设置',
          name: 'settings',
          icon: Icon(Icons.settings, size: 18),
          child: ChannelSettingPage(),
        ),
      ],
    );
  }
}